<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of Usuario
 *
 */
class User_Model_Session extends Zend_Db_Table_Abstract {
    protected $_name = 'sys_session';

   public function validateSessionByUser($username){
      
       $db = $this->getAdapter();

       $query = $db->select()->from($this->_name,array('id_session'))->where('id_user = ?',$username);
       $valor=$db->fetchRow($query);

       return $valor['id_session'];
       
   }

}
